import request from '@/utils/request'

export default {
  getChapterVideoList(id) {
    return request({
      url: '/eduservice/chapter/getChapterVideoList/' + id,
      method: 'get'
    })
  },
  saveChapter(chapter) {
    return request({
      url: '/eduservice/chapter/addChapter',
      method: 'post',
      data: chapter
    })
  },
  updateChapter(chapter) {
    return request({
      url: '/eduservice/chapter/updateChapter',
      method: 'put',
      data: chapter
    })
  },
  getChapterInfo(id) {
    return request({
      url: '/eduservice/chapter/getChapterInfo/'+id,
      method: 'get'
    })
  },
  deleteChapterById(id) {
    return request({
      url: '/eduservice/chapter/deleteChapter/'+id,
      method: 'delete'
    })
  }
}
